import service from "./request.js";

export default {
  // 修改用户
  update(query) {
    return service({
      method: "PUT",
      url: "/admin-api/system/user/update",
      data: query,
    });
  },
  // 修改用户状态
  updateStatus(query) {
    return service({
      method: "PUT",
      url: "/admin-api/system/user/update-status",
      data: query,
    });
  },
  // 新增用户
  create(query) {
    return service({
      method: "POST",
      url: "/admin-api/system/user/create",
      data: query,
    });
  },
  // 获得用户分页列表
  page(query) {
    return service({
      method: "GET",
      url: "/admin-api/system/user/page",
      params: query,
    });
  },
  // 获得用户详情
  get(query) {
    return service({
      method: "GET",
      url: "/admin-api/system/user/get",
      params: query,
    });
  },
  // 删除用户
  delete(query) {
    return service({
      method: "DELETE",
      url: "/admin-api/system/user/delete",
      params: query,
    });
  },
};
